
from view.endSrc.tHighDensityFilter import tHighDensityFilter
from view.endSrc.DBConfig import DBConfig
from view.endSrc.MySqlConn import MySqlConn


def CreateTable():

    cfg = DBConfig()
    sqlConn = MySqlConn(cfg)

    sqlConn.dropTable('tHighDensityFilter')

    f = tHighDensityFilter(sqlConn)
    res = f.createTable()
    print('createTable: ', res)


def CreateRows():

    cfg = DBConfig()
    sqlConn = MySqlConn(cfg)


    f = tHighDensityFilter(sqlConn)
    f.createRow(clusterEstimatorId=22, whichComponent=0, fromFilterId=111)
    f.updateOutputIds([1, 4], 'DensityPeakFilter', {"topPer": 0.2})




# CreateTable()
CreateRows()
